package com.woniuxy.user.mapper;

import com.woniuxy.commons.entity.*;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @author 吴毛伟
 * @date:2020/7/28 12:19
 * @description:
 */
@Repository
public interface UserMapper {

    public int getExam(int uid);

    public int selectExam(int uid);

    public int selectScore(int uid);

    LearnMap selectLearnMap(int uid, int id);

    int insertMap(int uid, int id);

    User selectUserByUname(String uname);

    CourseChapter findChapterByCid(int cid);

    int insertAnswers(ExamAnswer examAnswer);

    ExamAnswer selectExamAnswer(ExamAnswer examAnswer);

    int updateAnswer(ExamAnswer examAnswers);

    List<ExamAnswer> getAnswer(int examId, int uid);

    int insertByExamIdAndUserId(int paperId, int uid);

    ExamHistory findSatusByExamIdAndUserId(int paperId, int uid);

    int updateStatus1(int paperId, int uid);

    int updateStatus2(int paperId, int uid);

    List<User> selectAllUser();
}
